<div class="page-content" >
	<div class="panel panel-default">
		<div class="panel-heading">
			<ul class="breadcrumb">
				<li><a href="<{:U('index')}>">帖子分类</a></li>
				<li ><{$pidName}></li>
				<li >帖子列表</li>
			</ul>
		</div>
		<div class="panel-body">
			<div id="toolbar" style="width: 100%;">
				<form id="filter" method="get" action="<{:U('topic')}>" class="form-horizontal">
					<div class="form-group">
						<div class="col-sm-3">
							<input type="text" name="kw" style="margin-left:5px;" value="<{$_REQUEST['kw']}>" placeholder="用户名/昵称" />
						</div>
						<input type="hidden" name="group_id" value="<{$pid}>">
							<input type="hidden" name="type" value="<{$type}>">
						<div class="col-sm-4" style="float:right; width:auto">
							<input type="submit" class="btn btn-primary pull-right" value="筛选">
						</div>
					</div>
					<div class="form-group">
						<div class="col-sm-8"> <a  href="<{:U('Group/add_topic',array('group_id'=>$pid,'type'=>$type))}>" class="btn btn-default"> <i class="fa fa-plus"></i> 创建帖子 </a> </div>
					</div>
				</form>
			</div>
			<div class="bootstrap-table">
				<div class="fixed-table-container" style="padding-bottom: 0px;">
					<div class="fixed-table-body">
						<table id="data-table" class="table">
							<thead>
								<tr>
									<th style="" data-field="id"><div class="th-inner sortable both desc">ID</div>
										<div class="fht-cell"></div></th>
									<th style="" data-field="name"><div class="th-inner ">昵称</div>
										<div class="fht-cell"></div></th>
									<th style="" data-field="name"><div class="th-inner ">标题</div>
										<div class="fht-cell"></div></th>
										<th style="" data-field="name"><div class="th-inner ">排序</div>
										<div class="fht-cell"></div></th>
									<th style="" data-field="name"><div class="th-inner ">来自</div>
										<div class="fht-cell"></div></th>
									<th style="" data-field="name"><div class="th-inner ">评论数</div>
										<div class="fht-cell"></div></th>
									<th style="" data-field="name"><div class="th-inner ">点赞数</div>
										<div class="fht-cell"></div></th>
										<th style="" data-field="name"><div class="th-inner ">发布时间</div>
										<div class="fht-cell"></div></th>
									<th style="" data-field="id"><div class="th-inner ">操作</div>
										<div class="fht-cell"></div></th>
								</tr>
							</thead>
							<tbody>
								<volist name="data" id="vo">
									<tr data-index="0">
										<td height="36" align="center" valign="middle"><{$vo.id}></td>
										<td height="36" align="center" valign="middle"><a href="<{:U('Member/index',array('user_id'=>$vo['user_id']))}>"><{$vo.userInfo.nickname}></a></td>
										<td height="36" align="center" valign="middle" style="width:150px; padding:2px;"><p style="width:150px; padding:2px;"><{$vo.title}></p></td>
										<td style=""><input type="text" key="id" placeholder="顺序" onblur="set_order(this)" table="sns_topic" id="<{$vo.id}>" value="<{$vo.order_by}>"   /></td>
										<td height="36" align="center" valign="middle"><a href="<{:U('Group/index',array('group_id'=>$vo['pid']))}>"><{$vo.pidData.group_name}></a></td>
										<td height="36" align="center" valign="middle"><a href="<{:U('Group/comment',array('topic_id'=>$vo['id'],type=>$type))}>"><{$vo.comment_count}></a></td>
										<td height="36" align="center" valign="middle"><{$vo.good_count}></td>
										<td height="36" align="center" valign="middle"><{:date("Y-m-d H:i:s",$vo['dateline'])}></td>
										<td style="">

										 <a  href="<{:U('Group/add_topic',array('topic_id'=> $vo['id']))}>" class="btn btn-primary btn-xs">编辑</a>
										 <a   href="<{:U('Group/set',array('act'=>'is_top','topic_id'=> $vo['id']))}>"  class="btn btn-primary btn-xs"><{$vo['is_top']?'取消置顶':'置顶'}></a>

											<a   href="<{:U('Group/set',array('act'=>'is_best','topic_id'=> $vo['id']))}>"  class="btn btn-primary btn-xs"><{$vo['is_best']?'取消精选':'精选'}></a>

											<if condition="$type eq 'doc'">
											<a  target="_blank" href="<php>echo HomeUrl</php>/Index/content/topic_id/<{$vo['id']}>"  class="btn btn-primary btn-xs">查看</a>
											
										 <!--<a  href="<{:U('add_comment',array('topic_id'=> $vo['id'],type=>$type))}>" class="btn btn-primary btn-xs">添加评论</a>--> 
											</if>
											<a onClick=" return confirm('确认要删除吗？')" href="<{:U('Group/del_topic',array('ids'=> $vo['id']))}>" class="btn btn-primary btn-xs">删除</a>
											</td>
									</tr>
								</volist>
							</tbody>
						</table>
					</div>
					<include file="./Apps/BoxAdmin/View/Ace/Public/pager.html" /> </div>
			</div>
			<div class="clearfix"></div>
		</div>
	</div>
</div>
